home *** CD-ROM | disk | FTP | other *** search
- /*
- File: CappuccinoDef.h
-
- Contains: Common definitions used by Cappuccino.cpp & .r files.
-
- Written by: Steve Smith and Troy Gaul
-
- Copyright: © 1994-95 by Apple Computer, Inc., all rights reserved.
-
- -------------------------------------------------------------------
-
- Note: This file will need to be modified for any derivitive
- work based on Cappuccino. The areas marked with (CH)
- should be considered when making those changes.
- */
-
- #ifndef _CAPPUCCINODEF_
- #define _CAPPUCCINODEF_
-
- // -- OpenDoc Includes --
-
- #ifndef SOM_Module_OpenDoc_StdDefs_defined
- #include <StdDefs.xh>
- #endif
-
- //=====================================================================
-
- // Class / Editor ID (CH)
- #define kPartClassName "som_Cappuccino"
- #define kCappuccinoID "AppleComputer::"kPartClassName
-
- // Kind (CH)
- #define kCappuccinoKind kODISOPrefix "Apple:Kind:Cappuccino"
- #define kTextDataKind 'TEXT'
-
- // User Strings (CH)
- #ifdef qRezzing
- #define kCappuccinoEditorUserString "Cappuccino 1.0"
- #define kCappuccinoKindUserString "Cappuccino"
- #define kTextDataKindUserString "Text data"
- #endif
-
- // Category (CH)
- #define kCappuccinoCategory kODCategoryPlainText
-
- // Cappuccino OSTypes (CH)
- #define kCappuccinoEditorOSType 'CUED'
- #define kCappuccinoViewerOSType 'CUVW'
- #define kCappuccinoDocumentOSType 'CUDC'
- #define kCappuccinoStationeryOSType 'sUDC'
-
- // ISO Strings (CH)
- #define kMainPresentation kODISOPrefix "Cappuccino:Presentation:Main"
- #define kCappuccinoInfo kODISOPrefix "Cappuccino:Display Frame Info"
- #define kTextFontAnnotation kODISOPrefix "Cappuccino:Text Font"
- #define kTextSizeAnnotation kODISOPrefix "Cappuccino:Text Size"
- #define kDrawFrameAnnotation kODISOPrefix "Cappuccino:Draw Frame"
-
- // Cappuccino defines
- #define kBaseResourceID 20001
- #define kBaseCommandID 20001
-
- // NMAP Resource IDs
- #define kKindCategoryMapId kBaseResourceID+1
- #define kEditorKindMapId kBaseResourceID+2
- #define kEditorUserStringMapId kBaseResourceID+3
- #define kKindUserStringMapId kBaseResourceID+4
- #define kOldMacOSTypeMapId kBaseResourceID+5
- #define kPlatformEditorKindMapId kBaseResourceID+6
-
- // Category (CH)
- /*
- // This nmap is not used because we (like a good part), use one
- // of the standard categories listed in StdDefs.idl.
- #define kCategoryUserStringMapId kBaseResourceID+7
- #define kCappuccinoCategoryUserString "Plain Text"
- */
-
- // 'STR ' resources
- #define kDefaultStringID kBaseResourceID
-
- // 'STR#' resources
- #define kMenuStringResID kBaseResourceID
- #define kAboutTextID 1
-
- // Error Messages
- #define kErrStrFieldItem 3
- #define kErrorStringResID kBaseResourceID+1
- #define kErrCantInitializePart 1
- #define kErrCantOpenDocWindow 2
- #define kErrCantOpenPartWindow 3
- #define kErrRemoveFrame 4
- #define kErrWindowGone 5
- #define kErrExternalizeFailed 6
- #define kErrCantEditLinkDest 7
- #define kErrSpeechManagerProblem 8
-
- // Undo-related strings
- #define kActionStringResID kBaseResourceID+2
-
- #define kActionCodeMultiplier 2
- #define kUndoOffset 1
- #define kRedoOffset 2
-
- #define kActionCut 1
- #define kActionPaste 2
- #define kActionClear 3
- #define kActionDrag 4
- #define kActionDrop 5
- #define kActionSetText 6
- #define kActionChangeSettings 7
-
- // Bundles/FREFs
- #define kDocumentBundle kBaseResourceID
- #define kEditorBundle kBaseResourceID+1
- #define kViewerBundle kBaseResourceID+2
- #define kDocumentFREF kBaseResourceID
- #define kStationeryFREF kBaseResourceID+1
- #define kEditorFREF kBaseResourceID+2
- #define kViewerFREF kBaseResourceID+3
-
- // Icons
- #define kLargeIcons 1
- #define kSmallIcons 2
- #define kDocumentIcons kBaseResourceID
- #define kStationeryIcons kBaseResourceID+1
- #define kEditorIcons kBaseResourceID+2
- #define kViewerIcons kBaseResourceID+3
-
- // Pictures
- #define kEditorIconPicture kBaseResourceID
- #define kThumbnailPicture kBaseResourceID+1
-
- // Dialogs & Windows
- #define kAboutBoxID kBaseResourceID
- #define kErrorBoxID kBaseResourceID+1
- #define kMacWindowTitleBarHeight 20
- #define kALittleNudge 4
- #define kMinVertVisPortion 10
- #define kMinHorzVisPortion 16
- #define kWindowOpening kODTrue
- #define kWindowClosing kODFalse
-
- #define kSettingsDialogID kBaseResourceID+1000
- #define kSetTextDialogID kBaseResourceID+1001
-
- #define kDialogFontInfoID kBaseResourceID
- #define kSettingsFontIndex 1
-
- // Display Frames
- #define kFrameRemoved kODTrue
- #define kFrameClosed kODFalse
-
- // Geometry
- #define kMinImagingResolution 72 // dpi
-
- // Clipboard constants
- #define kIsForClipboard kODTrue
- #define kIsNotForClipboard kODFalse
-
- // Cappuccino menus (CH)
- #define kBaseMenuID kBaseResourceID
- #define kNumMenus 1
- #define kMiscMenuID kBaseMenuID
-
- #define kFontPopupMenuID kBaseMenuID+10
-
- // Cappuccino commands (CH)
- #define kCommandSettings kBaseCommandID
- #define kCommandSetText kBaseCommandID+1
- #define kCommandSpeak kBaseCommandID+2
-
-
- #endif
-
-